<template>
	<view>
		<uni-list>
			<uni-list-item :title="item.questionsname" v-for="(item,index) in downloadData" :key="index" @click="toDownDetail(item.questionsid)"></uni-list-item>
		</uni-list>
	</view>
</template>

<script>
	import userApi from "@/api/user.js"
	import uniList from '@/components/uni-list/uni-list.vue'
	import uniListItem from '@/components/uni-list-item/uni-list-item.vue'
	let _this;
	export default {
		components: {
			uniList,
			uniListItem
		},

		data() {
			return {
				downloadData:[]
			}
		},
		onLoad(query) {
			
			_this = this;
			

		},
		onShow() {
			_this.initData();
		},
		computed: {

		},
		methods: {
			initData() {
				let downloadData = uni.getStorageSync('download')
				console.log(downloadData)
				if(downloadData){
					_this.downloadData = downloadData
				}
			},
			toDownDetail(id){
				uni.navigateTo({
					url:`/pages/user/download/detail?id=${id}`
				})
			}

		}
	}
</script>

<style lang="scss" scoped>

</style>
